package com.xbongbong.saas.model.impl;

import com.xbongbong.paas.toolbox.exception.XbbException;
import com.xbongbong.saas.domain.dao.NoticeDao;
import com.xbongbong.saas.domain.entity.NoticeEntity;
import com.xbongbong.saas.model.NoticeModel;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;
import java.util.List;
import java.util.Map;

/**
 * @author long
 * @version v1.0
 * @date 2020/10/13 10:30
 * @since v1.0
 */
@Service("noticeModel")
public class NoticeModelImpl implements NoticeModel {

    @Resource
    private NoticeDao noticeDao;

    @Override
    public Integer insert(NoticeEntity entity) throws XbbException {
        return noticeDao.insert(entity);
    }

    @Override
    public Integer update(NoticeEntity entity) throws XbbException {
        return noticeDao.update(entity);
    }

    @Override
    public List findEntitys(Map<String, Object> param) {
        return noticeDao.findEntitys(param);
    }

    @Override
    public Integer getEntitysCount(Map<String, Object> param) {
        return noticeDao.getEntitysCount(param);
    }

    @Override
    public List findEntitysWithoutSub(Map<String, Object> param) {
        return null;
    }
}
